load("@rules_cc//cc:defs.bzl", "cc_library")

cc_library(
    name="TGPoint",
    srcs=["TGPoint.cpp"],
    hdrs=["TGPoint.h"],
    visibility=["//visibility:public"],
)
cc_library(
    name="TGLine",
    srcs=["TGLine.cpp"],
    hdrs=["TGLine.h"],
    deps=[
        ":TGPoint",
    ],
    visibility=["//visibility:public"],
)
cc_library(
    name="TGPolygon",
    srcs=["TGPolygon.cpp"],
    hdrs=["TGPolygon.h"],
    deps=[
        ":TGPoint",
        ":TGLine",
    ],
    visibility=["//visibility:public"],
)
cc_library(
    name="misc",
    srcs=["misc.cpp"],
    hdrs=["misc.h"],
    linkopts=['-pthread'],
    deps=[
        ":TGPoint",
        ":TGLine",
        ":TGPolygon",
        "@opencv//:opencv4",
    ],
    visibility=["//visibility:public"],
)